<template>
    <view class="content">
        <nav-bar ref="navBar" title="厨艺秀" :shadow="false" bg-color="#f7f7f7">领奖信息</nav-bar>
        <!-- 公共组件-每个页面必须引入 -->
        <public-module></public-module>
        <view class="info_list_box">
            <view class="info_box">
                <view class="name">
                    收件人
                </view>
                <input type="text" v-model="name" placeholder="请填写收件人的称呼" placeholder-class="grey" />
            </view>
            <view class="info_box">
                <view class="name">
                    联系方式
                </view>
                <input type="text" v-model="tel" placeholder="请填写收件人手机号码方便联系" placeholder-class="grey" />
            </view>
            <view class="info_box">
                <view class="name">
                    区域位置
                </view>
                <!-- <text class="value" v-if="addressInfo.address">{{ addressInfo.name }}</text>
				<text class="select" v-else="">请选择位置</text> -->

                <!-- <input type="text" v-model="add" placeholder="请选择位置" placeholder-class="grey" /> -->
            </view>
            <view class="info_box">
                <view class="name">
                    详细地址
                </view>
                <textarea placeholder="如道路、门牌号、小区、楼栋号单元、室等" placeholder-class="grey" />
            </view>
		</view>
		<button type="default" class="confirm">确定</button>

	</view>
</template>

<script>
	export default {
		data() {
			return {
				name: '',
				tel:'',
				add:'',
				add2:''
			};
		},
		//第一次加载
		onLoad(e) {
			this.pageData();

		},
		//页面显示
		onShow() {},
		//方法
		methods: {
			onPageJump(url) {
				uni.navigateTo({
					url: url
				});
			},
			pageData() {
				if (this.pageNo <= this.pages) {
					let httpData = {
						pageSize: 18,
						pageNo: this.pageNo,
					}
					this.$http.post("api/turntable/v1/my_gift", httpData, {
						load: false
					}).then(res => {
						uni.stopPullDownRefresh();
						this.pages = res.pages;
						if (this.pageNo == 1) {
							this.lotteryList = res.data
						} else {
							this.lotteryList = this.lotteryList.concat(res.data);
						}
						if (res.data.length > 0) {
							this.pageNo += 1
						}
					});
				}
			},
		},
		//页面隐藏
		onHide() {},
		//页面卸载
		onUnload() {},
		//页面下来刷新
		onPullDownRefresh() {
			this.pageNo = 1;
			this.pages = 1;
			//this.loadData();
		},
		//页面上拉触底
		onReachBottom() {
			this.pageData();
		},
		//用户点击分享
		onShareAppMessage(e) {
			return this.wxShare();
		}
	};
</script>
<style lang="scss" scoped>
	@import "@/style/mixin.scss";

	.content {
		background-color: #F7f7f7;
		min-height: 100vh;
		padding: 42rpx 32rpx;
	}

	.info_list_box {
		background-color: #fff;
		padding: 0 32rpx;
		border-radius: 8rpx;

		.info_box {
			padding: 32rpx 0;
			display: flex;
			//align-items: center;
			justify-content: space-between;
			border-bottom: 1rpx solid #e5e5e5;

			&:nth-child(4) {
				border-bottom: none;
			}

			.name {
				font-size: 28rpx;
				color: #333333;
				flex-shrink: 0;
			}

			input {
				margin-left: 40rpx;
				width: 100%;
				font-size: 28rpx;
				text-align: right;
				color: #333333;
			}
			textarea{
				height: 82rpx;
				margin-left: 40rpx;
				width: 100%;
				font-size: 28rpx;
				text-align: right;
				color: #333333;
			}

			.grey {
				color: #cccccc;
			}
		}
	}
	.confirm{		
	    height: 88rpx;
		background-image: linear-gradient(270deg, #1ec9ec 0%,#ff1d86 0%,#ff1dbb 100%);
		border-radius: 8rpx;
		font-size: 32rpx;
		color: #fff;
		margin-top: 24rpx;
	}
</style>
